package com.qxkj.youjian.controller;

import com.qxkj.youjian.service.MailService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * 邮件管理
 */
@RestController
@RequestMapping("/email")
public class MailController {

    @Autowired
    private MailService mailServiceImpl;

    /**
     * 发送一条消息
     * @param msg
     * @return
     */
    @RequestMapping(value = "/sendMsg", method = RequestMethod.POST)
    public String findUserByUserName(String msg) {
        String s = mailServiceImpl.sendMsgToMq(msg);
        System.out.println("akakakaAaakakak"+s);
        return s;
    }

}
